{% extends "grappelli/dashboard/module.html" %}
{% load i18n %}
{% block module_content %}
    {% spaceless %}
    {% for child in module.children %}
        <div class="grp-module" id="module-{{child.name|lower}}">
            <h{% if subindex %}4{% else %}3{% endif %}><a href="{{ child.url }}">{% trans child.name %}</a></h{% if subindex %}4{% else %}3{% endif %}>
            {% for model in child.models %}
                <div class="grp-row">
                    {% if model.admin_url %}
                        <a href="{{ model.admin_url }}"><strong>{{ model.title }}</strong></a>
                    {% else %}
                        <strong>{{ model.title }}</strong>
                    {% endif %}
                    {% if model.add_url or model.admin_url %}
                        <ul class="grp-actions">
                            {% if model.add_url %}
                                <li class="grp-add-link">
                                    <a href="{{ model.add_url }}">{% trans "Add" %}</a>
                                </li>
                            {% endif %}
                            {% if model.admin_url %}
                                <li class="grp-change-link">
                                    <a href="{{ model.admin_url }}">{% trans "Change" %}</a>
                                </li>
                            {% endif %}
                        </ul>
                    {% endif %}
                </div>
            {% endfor %}
        </div>
    {% endfor %}
    {% endspaceless %}
{% endblock %}
